﻿using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using Yes.Domain.Context;

namespace Yes.Web.Component
{
    public class HeadComponent: ViewComponent
    {
        private IUserContext _userContext;

        public HeadComponent(IUserContext userContext)
        {
            _userContext = userContext;
        }


        public IViewComponentResult Invoke()
        {
            return View("_Head", _userContext.CurrentUser);
        }
    }
}
